﻿//
// Created by Administrator on 2020/9/8.
//

#ifndef EXAMPLE_CPP_PERSON2_H
#define EXAMPLE_CPP_PERSON2_H

#include <iostream>
#include <string>

class Person2 {

private:
    std::string name;
    int age;

protected:
    inline const std::string getName() const {
        return name;
    };

    inline const int getAge() const {
        return age;
    };

public:
    Person2(const char *name, int age);

    virtual ~Person2();

    virtual void toString();

    friend std::ostream &operator<<(std::ostream &os, const Person2 &person);
};


#endif //EXAMPLE_CPP_PERSON2_H
